import { API } from '@/services/model/baseModel';
import { FAQModel, QuestionModel } from '@/services/model/questionModel';
import config from '@/utils/config';
import { request } from '@/utils/http';

/**
 * 问题列表
 * @returns
 */
const getQuestionList = () => {
  return request.get<API<FAQModel>>(config.url.question_list, {});
};

/**
 * 详细问题
 * @returns
 */
const getQuestionDetail = (id: number) => {
  return request.post<API<QuestionModel>>(config.url.question_detail, { id: id });
};
export { getQuestionList, getQuestionDetail };
